package com.ash.objecthead;

import org.openjdk.jol.info.ClassLayout;

import java.util.concurrent.TimeUnit;

/**
 * @Author: Ashin
 * @Date: 2021/3/25
 * @Description: com.ashin
 * @Version: 1.0.0
 */
public class Test {

    public static void main(String[] args)throws Exception {
        TimeUnit.SECONDS.sleep(5);
        Object instance = new Object();
        System.out.println(ClassLayout.parseInstance(instance).toPrintable());

        synchronized(instance){
            System.out.println(ClassLayout.parseInstance(instance).toPrintable());
        }
    }

}
